const Category = require('../../models/blog_category');

const ControllerCategory = {
    getList: async function (req, res, next) {
        try {
            const list = await Category.all();

            res.json({ code: 200, msg: '连接成功', data: { list } })
        } catch (e) {
            res.json({ code: 0, data: e })
        }
    }
}

module.exports = ControllerCategory;